{/include file="simpla/common/header.html"/}
{/include file="simpla/common/left.html"/}
<div id="main-content">
  <h2>欢迎您 {/$_adminname/}</h2>
  <p id="page-intro">查看和管理仓库。</p>
  <div class="clear"></div>
  <div class="content-box">
    <div class="content-box-header">
      <h3>仓库管理</h3>
      <ul class="content-box-tabs">
        <li><a href="#tab1" class="default-tab">仓库情况</a></li>
        <li><a href="{/get_url rule="/purchase/storeroom"/}">添加库存</a></li>
      </ul>
      <div class="clear"></div>
    </div>
    <div class="content-box-content">
      <div class="tab-content default-tab" id="tab1">
        <table>
          <thead>
            <tr>
              <th>仓库编码</th>
              <th>仓库名称</th>
              <th>位置</th>
              <th>库存</th>
              <th>状态</th>
              <th>管理</th>
               <th>备注</th>
           </tr>
          </thead>
          <tfoot>
            <tr>
              <td colspan="6">{/$pagebar/}</td>
            </tr>
          </tfoot>
          <tbody>
          {/section name=i loop=$storeroom/}
          <tr>
            <td>{/$storeroom[i].id/}</td>
            <td>{/$storeroom[i].title/}</td>
            <td>{/$storeroom[i].address/}</td>
            <td><span class="red fb">{/$storeroom[i].in_num-$storeroom[i].out_num/}</span></td>
            <td>{/$storeroom[i].status/}</td>
            <td>{/if $storeroom[i].out_num eq 0/}<a onclick="return(confirm('只有入库错误的时候才使用，你确认入库错误?'))" href="{/get_url rule='/storeroom/storeroom' data='ac=del&gid='|cat:$storeroom[i].id/}" title="删除"><img src="{/$root_dir/}/assets/simpla/images/icons/cross.png" alt="删除" /></a>&nbsp;{//if/}<a href="{/get_url rule='/storeroom/storeroom' data='gid='|cat:$storeroom[i].goods_id/}" title="入库"><img src="{/$root_dir/}/assets/simpla/images/icons/hammer_screwdriver.png" alt="入库" /></a></td>
             <td>{/$storeroom[i].rem/}</td>
         </tr>
          {//section/}
            </tbody>
        </table>
        <div class="form"> 
       <form action="{/get_url rule='/purchase/addstore'/}" method="post" id="js-form"> 
        <fieldset class="clearfix"> 
         <p> <label class="w80">仓库名称：<font class="red"> * </font></label> <span> <input type="text" value="" class="text-input small-input" name="title" id="title" /> </span></p> 
         <p> <label class="w80">仓库地址：<font class="red"> * </font></label> <span> <input type="text" value="" class="text-input small-input" name="address" id="address" /> </span></p> 
         <p> <label class="w80">仓库状态：<font class="red"> * </font></label> <span> <input type="text" value="" class="text-input small-input" name="status" id="status" /> </span></p> 
         <p> <label class="w80">备注：</label> <span> <input type="text" value="" class="text-input small-input" name="rem" id="rem" /> </span></p> 
         <input type="submit" name="" id="button" class="button" value="添加仓库" /> 
        </fieldset> 
       </form> 
      </div>
      </div>
    </div>
  </div>
  {/include file="simpla/common/copy.html"/} </div>
{/include file="simpla/common/footer.html"/}